package com.app.entity.resParams;

import com.alibaba.fastjson.annotation.JSONField;
import lombok.Data;

import java.util.Date;

/**
 * @author by jt on 2021/4/10
 */
@Data
public class OrdersCoachRes {


    private Integer id;

    /**
     * 预约计划id
     */
    private Integer subid;

    /**
     * 生成时间
     */
    private Date createTime;

    /**
     * 学员id
     */
    private Integer sid;

    /**
     * 逻辑撤销
     */
    private Integer deleted;

    /**
     * 备注
     */
    private String remarks;
    /**
     * 开始时间
     */
    private String startTime;

    /**
     * 结束时间
     */
    private String endTime;
    /**
     * 评分
     */
    private Integer score;

    private Character state;  // 0
    /**
     * 车牌号
     */
    private String carNum;
    private String username;
    private String tel;
    private String url;

    @JSONField(name = "stateName")
    public String stateName() {
        if (this.state == '0') {
            return "学时未审核";
        } else if (this.state == '1') {
            return "学时审核通过，未评价";
        } else {
            return "完成";
        }
    }
}
